STEP 1: First, we must prepare the variables needed to create the bricks that we will break!.

  • In LOGIC, from drag out two Integer Variable blocks. Rename the variables x and y.
  • Change x's value to -220 and y's value to 230. These coordinates will start our bricks in the top left corner!
  • From add an Empty List and name it bricks. We will add bricks to this list as we create them. Later, we will use this list to test if the player has broken all the bricks and won the game!

To navigate the page using the TAB key, first press ESC to exit the code editor.

# THIS ACTIVITY IS IN PREVIEW ONLY MODE
  • Run Code
  • Submit Work
  • Next Activity
  • Show Console
  • Reset Code Editor
  • Codesters How To (opens in a new tab)